package top.toptimus.dto.stock;

import lombok.Data;
import lombok.NoArgsConstructor;
import top.toptimus.util.DateTimeUtil;

import java.util.Date;

@NoArgsConstructor
@Data
public class StockInOutDetailDTO {
    private String barcode;
    private String batchNo;//批号

    private String styleNameCn; //  款式名称
    private String styleSizeCd;//尺码

    private String fabricId;
    private String fabricCode;
    private String fabricName;
    private String fabricComposition;

    private Date salesTime;
    private Integer inOutFlag;
    private String inOutType;
    private String storeId;
    private String storeName;

    //  货号信息
    private String refStyleId;
    private String inventory;
    private double price;

    public StockInOutDetailDTO(
            String barcode,
            String batchNo,
            String styleNameCn,
            String styleSizeCd,
            String fabricId,
            String fabricCode,
            String fabricName,
            String fabricComposition,
            Integer inOutFlag,
            String inOutType,
            String storeId,
            String refStyleId,
            String inventory,
            double price
    ) {
        this.barcode = barcode;
        this.batchNo = batchNo;
        this.styleNameCn = styleNameCn;
        this.styleSizeCd = styleSizeCd;
        this.fabricId = fabricId;
        this.fabricCode = fabricCode;
        this.fabricName = fabricName;
        this.fabricComposition = fabricComposition;
        this.inOutFlag = inOutFlag;
        this.inOutType = inOutType;
        this.storeId = storeId;
        this.salesTime = DateTimeUtil.getCurrentDate();

        this.refStyleId = refStyleId;
        this.inventory = inventory;
        this.price = price;
    }

    public StockInOutDetailDTO(
            String barcode,
            String batchNo,
            String styleNameCn,
            String styleSizeCd,
            String fabricId,
            String fabricCode,
            String fabricName,
            String fabricComposition,
            Date salesTime,
            Integer inOutFlag,
            String inOutType,
            String storeId,
            String storeName,
            String refStyleId,
            String inventory,
            double price
    ) {
        this.barcode = barcode;
        this.batchNo = batchNo;
        this.styleNameCn = styleNameCn;
        this.styleSizeCd = styleSizeCd;
        this.fabricId = fabricId;
        this.fabricCode = fabricCode;
        this.fabricName = fabricName;
        this.fabricComposition = fabricComposition;
        this.salesTime = salesTime;
        this.inOutFlag = inOutFlag;
        this.inOutType = inOutType;
        this.storeId = storeId;
        this.storeName = storeName;
        this.refStyleId = refStyleId;
        this.inventory = inventory;
        this.price = price;
    }
}
